home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Tech Arsenal 1
/
Tech Arsenal (Arsenal Computer).ISO
/
tek-04
/
msh20.zip
/
MSHFILES.ZIP
/
MENU.MSH
< prev
next >
Wrap
Text File
|
1992-03-26
|
6KB
|
181 lines
| file MENU.MSH where menus are defined
|
(normal_att current_att current_selected_att false true menu.install)
permanent_menu!
(normal_att current_att current_selected_att "hv" true menu.install)
permanent_bordered_menu!
(normal_att current_att current_selected_att "hv" false menu.install)
temp_bordered_menu!
|
((quit)(cmdlist prog_dir"cmdlst"& write quit)
"just %quit%
or also %save% your cmd stack?"
() "-1" 12 temp_bordered_menu)qmenu!
|
("your turn""please create your own menu here"message)yourmenu!
|
(floppy_drives fixed_drives &
0 i!
(dup length i >)
(i 1 + i! dup i i substring ":\""& "(\""swap& "cwd!refresh)"& # swap)
while
0 i!"" swap
(dup length i >)
(i 1 + i! dup i i substring ":%"&" "&" %"swap& 3 roll swap& swap)
while
drop
" Goto"nl& swap&
() linescols i 4 * 2+ - swap 2/ menu_line+
permanent_bordered_menu drive_menu_no!)
drive_menu!
|
(drive_menu_no window.activate)dmenu!
|
((ascii)(ls_MU)(dosmenu)(panel_stats)(prog_dir "cmdlst"&read cmdlist!)
(toggle_menu)(true capt_screen)
(selected_fit_other)(reconfig)(swap_menu)
" ShiftF1 %ascii table%
CtrlL %disk stats%
ShiftF7 %DOS commands%
%panels stats%
%read old command stack%
ShiftF4 %1/2 line top menu%
ShiftF5 %capture screen%
ShiftF2 %space on other panel%
F9 %change configuration%
ShiftF10 %swap menu%" (main_menu) 20 menu_line 1+ temp_bordered_menu)imenu!
|
(("chkdsk "exec)("format a:"exec)("c:\" cwd"!"format a: /s"exec)
("format b:"exec)("format b: /n:9 /t:80" exec)
(" warning "" Either you don't know what you're doing, and Mi-Shell
is not going to protect you from big mistakes,
or you are kidding, and so are we . . . !"message)
"%chkdsk%
%format a:%
%format a: bootable%
%format b: (1.4M)%
%format b: (720K in 1.4M drive)%
%format C:%
" (main_menu) 15 menu_line 1+ temp_bordered_menu)dosmenu!
|
|
((select_on_off)(copy_files)(move_files)(delete_files)(whereis)(find_string)
("pkzip " "what zip file do you want to create or update?"
50 input & " "& selected_list & exec)
(editor exec)(file_stats)("copy "current.name &" prn"& exec)
" F2 %select%
F5 %copy% selected
F6 %move% selected
F8 %delete% selected
%find a file%
%find a string%
%zip% selected
%edit new%
CtrlF9 %specs% of current file
%print%" (main_menu) 1 menu_line 1+ temp_bordered_menu)fmenu!
|
((browse_current)(editor current.name & exec)
(editor selected_list deselect & exec)(od)(wc)
(browser selected_list deselect & (exec) with_nomagic)
" F3 %view current%
F4 %edit current%
%edit selected%
ShiftF3 %hex dump%
%word count selected%
CtrlF3 %browse selected%" (main_menu) 8 menu_line 1+ temp_bordered_menu)vmenu!
|
((expand_panel)(trim_panel)(hide_all)(wide_narrow)(top_bottom)(swap_panels)
(refresh)("N" panel.sort!)("E" panel.sort!)("S" panel.sort!)("T" panel.sort!)
" CtrlE %Expand% panel
CtrlT %Trim% panel
CrtlO %hide% panels and menus
(toggle)
AltW %Wide/narrow toggle%
%top/bottom toggle%
CtrlU %swap% panels
CtrlR %Refresh% panel
Sort Panel by
AltN %Name%
AltE %Extension%
AltS %Size%
AltT %Time%
" (main_menu) 35 menu_line 1+ temp_bordered_menu)pmenu!
|
((browse_current)(editor current.name&exec)("ZOO "current.name &execshow)
" It is simple to associate a menu with an extension:
What the hell do you want to do to this
poor little Stephan file ?
%view it% could have used F3 or click right
%edit it% could have used F4 or double click right
%ZOO it% try it if you dare, no shortcuts for this one."
() 10 10 temp_bordered_menu)stemenu!
| ┌───────────┐
| │ Help menu │
| └───────────┘
|
("help.msh"loaddefs help_menu)hmenu!
|
| ┌────────────┐
| │ Magic menu │
| └────────────┘
|
| show state of magic switch -- if activated call "swapping type" menu
|
("magic_menu_no"isdefined(magic_menu_no window.uninstall)if
(swap_menu)magic dup (dup 1 1 substring "*"=
("*"cutfirst swap drop ("% D%")("% %")ifelse)
(drop"%XD%")ifelse)(drop"%X %")ifelse
() 78 0 permanent_menu magic_menu_no!)
magic_menu!
| ┌───────────────┐
| │ swapping menu │
| └───────────────┘
|
((false magic!magic_menu)(tmp_dir magic!magic_menu)
("*"tmp_dir&magic!magic_menu)("*"magic!magic_menu)
" What type of swapping do you want:
%XMS% (default)
%to directory "tmp_dir&"% if no XMS
%to directory "&tmp_dir&"% always
%no swapping%"&
() 30 4 temp_bordered_menu)swap_menu!
|
| toggle between one-line and two-line main menu
|
( menu_line 0=(1 menu_line!)(0 menu_line!)ifelse
(panel.startrc swap menu_line 0= ("-1")(1)ifelse + swap panel.startrc!
)loop_panels
main_menu_no window.uninstall
show_menu clock
)toggle_menu!
|
( menu_line 0=
| ┌───────────────────────┐
| │ Main menu -- 1 line │
| └───────────────────────┘
|
((hmenu)(fmenu)(vmenu)(imenu)(CtrlW)(pmenu)(personal_menu)(qmenu)
"F1%Help% %Files% %View/edit% %mIsc% %Whereto% %Panel% %Special% F10%Quit% "
() 0 0 permanent_menu main_menu_no!
0 menu_line!)
|
| ┌───────────────────────┐
| │ Main menu -- 2 lines │
| └───────────────────────┘
|
((hmenu)(select_on_off)(browse_current)(editor current.name & exec)
(copy_files)(move_files)(yourmenu)(delete_files)(reconfig)(qmenu)
(ascii)(selected_fit_other)(od)(toggle_menu)
(true capt_screen)(ls_hide)(dosmenu)(delta) (whereto)(swap_menu)
"F1 %Help% F2 %sel% F3 %view% F4 %edit% F5 %copy% F6 %mv% F7 %menu% F8 %del% F9 %cfg% F10 %Quit%
Shft %asci% %fito% %hex% %½ menu% %screen% %ls-hide% %DOS% %delta% %Whereto% %magic%"
() 0 0 permanent_menu main_menu_no!
1 menu_line!)
ifelse
)show_menu!
|
(main_menu_no window.activate)main_menu!
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||